翻訳と辞書
Words near each other
・ Bilimono
・ Bilimora
・ Bilin
・ Bilin (biochemistry)
・ Bilin Bilin
・ Bilin River
・ Bilin Township
・ Bilin, Mon State
・ Bilina
・ Bilina, Croatia
・ Bilinda Butcher
・ Bilinea
・ Bilinea bilineata
・ Bilinea bilineatissima
・ Bilinear
Bilinear filtering
・ Bilinear form
・ Bilinear interpolation
・ Bilinear map
・ Bilinear program
・ Bilinear quadrilateral element
・ Bilinear time–frequency distribution
・ Bilinear transform
・ Bilinear transformation
・ Bilinga
・ Bilinga (wood)
・ Bilinga, Queensland
・ Bilinga, Republic of the Congo
・ Bilingual (album)
・ Bilingual (disambiguation)


Dictionary Lists
翻訳と辞書 辞書検索 [ 開発暫定版 ]
スポンサード リンク

Bilinear filtering : ウィキペディア英語版
Bilinear filtering

Bilinear filtering is a texture filtering method used to smooth textures when displayed larger or smaller than they actually are.
Most of the time, when drawing a textured shape on the screen, the texture is not displayed exactly as it is stored, without any distortion. Because of this, most pixels will end up needing to use a point on the texture that is "between" texels, assuming the texels are points (as opposed to, say, squares) in the middle (or on the upper left corner, or anywhere else; it does not matter, as long as it is consistent) of their respective "cells". Bilinear filtering uses these points to perform bilinear interpolation between the four texels nearest to the point that the pixel represents (in the middle or upper left of the pixel, usually).
==The formula==
In a mathematical context, bilinear interpolation is the problem of finding a function f(x,y) of the form
:
f(x,y) = c_ xy + c_ x + c_ y + c_

satisfying
:
\begin
f(x_1,y_1) = z_ \\
f(x_1,y_2) = z_ \\
f(x_2,y_1) = z_ \\
f(x_2,y_2) = z_ \\
\end

The usual, and usually computationally least expensive way to compute f is through linear interpolation used twice, for example to compute two functions f_1 and f_2 satisfying
:
\begin
f_1(y_1) = z_ \\
f_1(y_2) = z_ \\
f_2(y_1) = z_ \\
f_2(y_2) = z_ \\
\end

and then to combine these functions (which are linear in y) into one function f satisfying
:
\begin
f(x_1,y) = f_1(y) \\
f(x_2,y) = f_2(y) \\
\end

In computer graphics, bilinear filtering is usually performed on a texture during texture mapping, or on a bitmap during resizing. In both cases, the source data (bitmap or texture) can be seen as a two-dimensional array of values z_, or several (usually three) of these in the case of full-color data. The data points used in bilinear filtering are the 2x2 points surrounding the location for which the color is to be interpolated.
Additionally, one does not have to compute the actual coefficients of the function f; computing the ''value'' f(x,y) is sufficient.
The largest integer not larger than x shall be called (), and the fractional part of x shall be \. Then, x = () + \, and \ < 1.
We have x_1 = (), x_2 = () + 1, y_1 = (), y_2 = () + 1.
The data points used for interpolation are taken from the texture / bitmap and assigned to
z_, z_, z_, and z_.
f_(y_) = z_,
f_(y_) = z_ are the two data points for f_
subtracting the former from the latter yields
:f_(y_) - f_(y_) = z_ - z_
Because f_ is linear, its derivative is constant and equal to
:(z_ - z_) / (y_ - y_) = z_ - z_
Because f_(y_) = z_,
:f_(y_ + \) = z_ + \(z_ - z_)
and similarly,
:f_(y_ + \) = z_ + \(z_ - z_)
Because y_ + \ = y, we have computed the endpoints f_(y) and f_(y) needed for the second interpolation step.
The second step is to compute f(x,y), which can be accomplished by the very formula we used for computing the intermediate values:
:f(x,y) = f_(y) + \(f_(y) - f_(y))
In the case of scaling, y remains constant within the same line of the rescaled image, and storing the intermediate results and reusing them for calculation of the next pixel can lead to significant savings. Similar savings can be achieved with all "bi" kinds of filtering, i.e. those which can be expressed as two passes of one-dimensional filtering.
In the case of texture mapping, a constant x or y is rarely if ever encountered, and because today's (2000+) graphics hardware is highly parallelized, there would be no time savings anyway.
Another way of writing the bilinear interpolation formula is
:f(x,y) = (1-\)((1-\)z_ + \z_) + \((1-\)z_ + \z_)

抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)
ウィキペディアで「Bilinear filtering」の詳細全文を読む



スポンサード リンク
翻訳と辞書 : 翻訳のためのインターネットリソース

Copyright(C) kotoba.ne.jp 1997-2016. All Rights Reserved.